package com.dyit.config;

import org.springframework.amqp.core.DirectExchange;
import org.springframework.amqp.core.TopicExchange;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

@Configuration
public class ExchangeConfig{
    @Bean
    public TopicExchange topicExchange(){
        return new TopicExchange(RabbitMqConfig.TOPIC_EXCHANGE,true,false);
    }

    @Bean
    public DirectExchange directExchange(){
        return new DirectExchange(RabbitMqConfig.DIRECT_EXCHANGE,true,false);
    }


}
